---@class SkillEffect302100:BaseSkillEffect
SkillEffect302100 = ClientFight.CreateClass("SkillEffect302100",ClientFight.BaseSkillEffect)
local t = SkillEffect302100

function t:releaseSkill(skill)
    local fighter = skill.fighter
    local scriptParam = skill.skill.skillBean.f_SkillScriptParameter
    local passiveskills = fighter.passiveskills
    for k,fs in pairs(passiveskills) do
        if (fs.skillBean.f_SkillID / 1000 == scriptParam[2]) then
            BuffManager.addBuff(skill.fight, skill, fighter, fighter, false, scriptParam[1], 1, fighter, skill);
            BuffManager.addBuff(skill.fight, skill, fighter, fighter, false, fs.skillBean.f_SkillID, 1, fighter, skill);
        end
    end
    return false;
end
---@param skill FightUsingSkill
function t:finishSkill(skill,breakin)
    local fighter = skill.fighter
    local skills = fighter.skills
    local scriptParam = skill.skill.skillBean.f_SkillScriptParameter
    for k, fs in pairs(skills) do
        if (fs.skillBean.f_SkillID / 1000 == scriptParam[2]) then
            local buff1 = BuffManager.getBuffByModel(fighter, scriptParam[1]);
            local buff2 = BuffManager.getBuffByModel(fighter, fs.skillBean.f_SkillID);
            BuffManager.removeFighterBuff(skill.fight, fighter, buff1, true);
            BuffManager.removeFighterBuff(skill.fight, fighter, buff2, true);
        end
    end
    return false;
end

t.New()